-- GENERATED SPELL FOR [Frenzyheart Ravager] --


function spell0_28078(pUnit, Event) --@Frenzy,Self--
pUnit:FullCastSpellOnTarget(53361,pUnit)
pUnit:RegisterEvent('Sorts_28078', 12262, 1)
end

function spell1_28078(pUnit, Event) --@Whirlwind,Self--
pUnit:FullCastSpellOnTarget(15578,pUnit)
pUnit:RegisterEvent('Sorts_28078', 585, 1)
end

function spell2_28078(pUnit, Event) --@Whirlwind,Self--
pUnit:FullCastSpellOnTarget(49807,pUnit)
pUnit:RegisterEvent('Sorts_28078', 2000, 1)
end

function Sorts_28078(pUnit, Event)
local choix_sorts_28078 = math.random(0, 2)
if choix_sorts_28078 == 0 then
pUnit:RegisterEvent('spell0_28078', 1, 1)
end
if choix_sorts_28078 == 1 then
pUnit:RegisterEvent('spell1_28078', 1, 1)
end
if choix_sorts_28078 == 2 then
pUnit:RegisterEvent('spell2_28078', 1, 1)
end
end

function mob28078_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_28078', math.random(1500, 3000), 1)
end

function mob28078_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob28078_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob28078_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(28078, 1, 'mob28078_Action')
RegisterUnitEvent(28078, 2, 'mob28078_Leave')
RegisterUnitEvent(28078, 3, 'mob28078_Kill')
RegisterUnitEvent(28078, 4, 'mob28078_Die')
